package com.vpen.account.demo.service.impl;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.vpen.account.demo.dao.AccountUserRoleDao;
import com.vpen.account.demo.entity.AccountRole;
import com.vpen.account.demo.entity.AccountUserRole;
import com.vpen.account.demo.service.AccountUserRoleService;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 用户确实表，一个用户多个角色，一对多(AccountUserRole)表服务实现类
 *
 * @author vpen
 * @since 2022-08-16 09:48:59
 */
@Service("accountUserRoleService")
public class AccountUserRoleServiceImpl extends ServiceImpl<AccountUserRoleDao, AccountUserRole> implements AccountUserRoleService {


    @Override
    public List<AccountRole> getUserRolesByUserId(Long userId) {
        return this.baseMapper.getUserRolesByUserId(userId);
    }
}

